In addition to the required atoms, the effects description contains a variable number of parameter atoms. The number and types of parameter atoms vary from effect to effect. For example, the built-in Cross Fade effect has only one parameter, while the General Convolution Filter effect has nine. Some effects will have no parameters at all, and do not require any parameter atoms. The section "Built-in QuickTime Video Effects" describes the parameters expected by the built-in effects.
The QTInsertChild function is used to add these parameters to the effect description, as seen in the code example in Listing 20-1 .
Consider, for instance, the Push effect [link] . In this example, the source `srcB' will push in from the bottom, covering the source `srcA' . The `pcnt' parameter atom defines which frame of the effect is shown. This should always contain a tween entry, so that the value of this parameter is interpolated as the effect runs. This will cause consecutive frames of the effect to be executed, allowing the push effect to take place.
In this example, the effect will start 25% of the way through (with `srcB' already partly on screen) and finish 75% of the way through (with part of `srcA' still visible).
Figure 20-1 shows the set of atoms that must be added to the entry description.
Figure 1 An example effect description for the Push effect
| Previous | Chapter contents | Chapter top | Section top | Next |